package com.fangshicai.controller;

import com.fangshicai.service.imple.StudentServiceimple;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @ClassName mybatisController
 * @Description TODO
 * @Author fangshicai
 * @Date 2021/7/18 10:47
 */
@Controller
public class mybatisController {

    @Autowired
    StudentServiceimple studentService;
    @GetMapping("/mybatis")
    @ResponseBody
    public Object query(@RequestParam("id") int id){
        return  studentService.queryStudentById(id);
    }
}
